<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
    <title>Title</title>
    <link rel="stylesheet" type="text/css" href="/libs/bootstrap/css/bootstrap.min.css">
    <link rel="stylesheet" type="text/css"
          href="http://pinzafile.oss-cn-shanghai.aliyuncs.com/admin/product/libs/font-awesome/css/font-awesome.min.css">
    <link rel=stylesheet href="/css/style.css" type="text/css">
    <link href="http://pinzafile.oss-cn-shanghai.aliyuncs.com/publiccss/assets/global/plugins/layui/css/layui.css" rel="stylesheet" type="text/css"/>
    <link href="/css/style-shop.css" rel="stylesheet" type="text/css">
    <link href="/css/shopdetail.css" rel="stylesheet" type="text/css">

</head>
<body class="body">

<div class="page-header">
    <div class="page-header-top">
        <div class="container">
            <!-- LOGO -->
            <div class="page-logo">
                <a href="index.html">
                    <img src="image/logo.png" alt="logo" class="pinza-logo">
                </a>
            </div>
            <!--菜单-->
            <div class="top-menu">
                <ul class="nav pull-right">
                    <!--个人中心-->
                    <li class="dropdown dropdown-extended dropdown-dark dropdown-inbox" id="header_inbox_bar">
                        <a href="http://pinzabim.oss-cn-shanghai.aliyuncs.com/Optional/home.html" target="_blank">选装体验</a>
                    </li>
                    <!-- 个人中心 -->
                    <#--<li class="dropdown dropdown-user dropdown-dark">-->
                        <#--<a href="javascript:;"  id="delete">-->
                            <#--<span class="username username-hide-mobile">登录</span>-->
                        <#--</a>-->
                    <#--</li>-->
                    <li class="dropdown dropdown-user dropdown-dark">
                        <a href="/index.page">
                            <span class="username username-hide-mobile">客户中心</span>
                        </a>
                    </li>
                    <li class="dropdown dropdown-user dropdown-dark">
                        <a href="shopcar.html">
                            <span class="username username-hide-mobile">购物车</span>
                        </a>
                    </li>
                </ul>
            </div>

            <div class="clearfix"></div>
        </div>
    </div>

</div>
<div class="main">
    <div class="container">
        <div class="row">
            <ul class="breadcrumb">
                <li><a href="index_2.html">首页</a></li>
                <li class="active">订单列表</li>
            </ul>
        </div>
        <div class="row back margin_border">
            <h3 style="padding: 15px 0">订单列表</h3>
        </div>
        <div class="row back">
            <div class="col-sm-12">
                <div class="goods-page">
                    <div class="goods-data clearfix">
                        <div class="table-wrapper-responsive">
                            <table summary="Shopping cart">
                                <tr>
                                    <th class="goods-page-description">材料编码</th>
                                    <th class="goods-page-description">SKU名称</th>
                                    <th class="goods-page-description">品牌</th>
                                    <th class="goods-page-description">价格</th>
                                    <th class="goods-page-description">数量</th>
                                    <th class="goods-page-description">单位</th>
                                    <th class="goods-page-description">详情</th>
                                    <th class="goods-page-description">操作</th>
                                </tr>

                                <#list list as map>
                                        <tr>
                                            <td class="goods-page-image">
                                                <a href="javascript:;">${map.sku_code}</a>
                                            </td>
                                            <td class="goods-page-description">
                                                <strong><span>${map.sku_name}</span></strong></td>

                                            <td class="goods-page-quantity">
                                                卡瑞
                                            </td>
                                            <td class="goods-page-total">
                                                <strong>${map.sku_cost_price}</strong>
                                            </td>
                                            <td class="goods-page-ref-no">
                                                <div class="layui-input-inline" style="width: 100px;">
                                                    <input type="text" name="num" oncuechange="checkPrice()" value="1" autocomplete="off" class="layui-input">
                                                </div>
                                            </td>
                                            <td class="goods-page-ref-no">
                                                <strong><span>㎡</span></strong>
                                            </td>
                                            <td class="goods-page-description">
                                                <h3><a href="javascript:;">南次卧飘窗柜【定制】。</a></h3>
                                                <p><strong>规格：</strong> 颜色: 原木色; 尺寸: 150mm</p>
                                                <em>查看更多</em>
                                            </td>
                                            <td class="del-goods-col">
                                                <button class="layui-btn layui-btn-sm layui-btn-danger" onclick="delSku(${map.order_id})">删除</button>
                                            </td>
                                        </tr>
                                </#list>
                            </table>
                        </div>

                        <div class="shopping-total">
                            <ul>
                                <li>
                                    <span>产品价格</span>
                                    <strong class="price"><span>$</span>58,980.00</strong>
                                </li>
                                <li class="shopping-total-price">
                                    <span>总计</span>
                                    <strong class="price"><span>¥</span>59,280.00</strong>
                                </li>
                            </ul>
                        </div>
                    </div>
                    <a href="../productDesk/index.html">
                        <button class="btn btn-default" type="submit">继续添加 <i class="fa"></i></button>
                        <a href="/order/address.page">
                            <button class="btn btn-primary" type="submit">提交订单 <i class="fa"></i></button>
                        </a>
                    </a>
                </div>
            </div>
            <!-- END CONTENT -->
        </div>
    </div>
</div>
<script src="http://pinzafile.oss-cn-shanghai.aliyuncs.com/publiccss/assets/global/plugins/jquery.min.js" type="text/javascript"></script>
<script src="http://pinzafile.oss-cn-shanghai.aliyuncs.com/publiccss/assets/global/plugins/layui/layui.js"  type="text/javascript"></script>
</body>
<script>
    var layer = '';
    layui.use(['layer'], function(){
        layer = layui.layer
    });
    function delSku(val) {
        layer.confirm('移除购物车?', {icon: 3, title:'提示'}, function(index){
            //do something
            $.ajax({
                url: '/role/list.json',
                type: 'post',
                data: {key:key,page:page,size:size},
                async: false,
                dataType: 'json',
                success: function (result) {
                    if(result.ret){
                        resultData = result.data;
                    }
                }
            });
            layer.close(index);
        }); 
    }
    console.log()
    function checkPrice() {
        var num = $("input[name='num']");
        var price = $("div .goods-page-total strong");
        var sum = 0
        for (var i = 0;i<num.length;i++){

        }
    }
</script>
</html>